package com.neusoft.bookstore.menu.mapper;


import com.neusoft.bookstore.menu.model.Menu;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface MenuMapper {

    Menu findMenuByParentMenuCodeAndName(Menu menu);

    Menu findMenuByMenuCode(String menuCode);

    void updateTypeAndUrlByCode(String parentMenuCode);

    int insertMenu(Menu menu);

    List<Menu> listMenus();

    int updateMenuByCode(Menu menu);

    List<Menu> findChildMenus(String menuCode);

    int deleteMenuByCode(String menuCode);
}
